package com.rd.student.jiaji.class4.suyan.zrrd.homework2;

import java.util.Arrays;
import java.util.Random;

public class 第二种练习方式 {
    public static void main(String[] args) {
        boolean[] color =new boolean[35];
        int[] red =new int[5];
        Random random=new Random();
        int index=0;
        int index1=0;
        boolean[] color1=new boolean[12];
        int[] red2 =new int[2];
        for (;;){ int b=random.nextInt(12);
            if (!color[b]){
                red2[index1]=b+1;
                index1++;
            }
            if (index1==2){
                break;
            }
        }
        System.out.println(Arrays.toString(red2));
        for (;;){
            int a=random.nextInt(35);
            if (!color[a]){

                red[index]=a+1;
                index++;
            }
            if (index==5){
                break;
            }

        }
        System.out.println(Arrays.toString(red));



    }


    }

